package cn.net.yato.picture.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * @ClassName UserHeadImg
 * @Description 用户头像图片
 * @Author yato
 * @Date 2020/2/17 13:28
 * @Version 1.0
 */
@Data
@TableName(value = "userheadimg")
public class UserHeadImg implements Serializable {
    /**
     * 自增id
     */
    @TableId(value = "id", type = IdType.AUTO)
    private long id;
    /**
     * 图片id
     */
    @TableField(value = "file_id")
    private String fileId;
    /**
     * 上传用户id 对应用户表
     */
    @TableField(value = "user_id")
    private String userId;
    /**
     * 文件名
     */
    @TableField(value = "file_name")
    private String fileName;
    /**
     * 文件大小
     */
    @TableField(value = "file_size")
    private Double fileSize;
    /**
     * 文件访问路径
     */
    @TableField(value = "file_path")
    private String filePath;
    /**
     * 文件服务器路径
     */
    @TableField(value = "file_loc_path")
    private String fileLocPath;
    /**
     * 文件上传时间
     */
    @TableField(value = "file_update_time")
    private Date fileUpdateTime;
    /**
     * 状态
     * 1：使用
     * 0：未使用
     */
    @TableField(value = "file_state")
    private int fileState;

    public UserHeadImg() {
    }

    public UserHeadImg(long id, String fileId, String userId, String fileName, Double fileSize, String filePath, String fileLocPath, Date fileUpdateTime, int fileState) {
        this.id = id;
        this.fileId = fileId;
        this.userId = userId;
        this.fileName = fileName;
        this.fileSize = fileSize;
        this.filePath = filePath;
        this.fileLocPath = fileLocPath;
        this.fileUpdateTime = fileUpdateTime;
        this.fileState = fileState;
    }

    public long getId() {
        return id;
    }

    public void setId(long id) {
        this.id = id;
    }

    public String getFileId() {
        return fileId;
    }

    public void setFileId(String fileId) {
        this.fileId = fileId;
    }

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public String getFileName() {
        return fileName;
    }

    public void setFileName(String fileName) {
        this.fileName = fileName;
    }

    public Double getFileSize() {
        return fileSize;
    }

    public void setFileSize(Double fileSize) {
        this.fileSize = fileSize;
    }

    public String getFilePath() {
        return filePath;
    }

    public void setFilePath(String filePath) {
        this.filePath = filePath;
    }

    public String getFileLocPath() {
        return fileLocPath;
    }

    public void setFileLocPath(String fileLocPath) {
        this.fileLocPath = fileLocPath;
    }

    public Date getFileUpdateTime() {
        return fileUpdateTime;
    }

    public void setFileUpdateTime(Date fileUpdateTime) {
        this.fileUpdateTime = fileUpdateTime;
    }

    public int getFileState() {
        return fileState;
    }

    public void setFileState(int fileState) {
        this.fileState = fileState;
    }
}
